home *** CD-ROM | disk | FTP | other *** search
/ ShareWare OnLine 2 / ShareWare OnLine Volume 2 (CMS Software)(1993).iso / comm2 / tb118.zip / TB113FF.PAS < prev    next >
Pascal/Delphi Source File  |  1993-03-10  |  14KB  |  462 lines

  1. { TurBoard v1.12 File Formats                         March , 1993 }
  2.  
  3. { (c) Copyright Shawn Rhoads 1993, ALL RIGHTS RESERVED }
  4. { (c) Copyright Software @ Work 1993, ALL RIGHTS RESERVED }
  5.  
  6. { This change may be somewhat painful, but we've add RESERVED space for
  7.   just about every file format available, so hopefully, this will take care
  8.   of most of the file format upgrades for some time to come. }
  9.  
  10.  
  11. { We haven't taken the time to convert all of the record types over to C
  12.   for those of you who requested C file formats as well.  Here is some
  13.   information that you will find useful in doing the conversion yourself:
  14.  
  15.   Pascal Type  C Type        Actual Space Used
  16.   -----------  ------------  -----------------------------------------
  17.   byte         char          one byte
  18.   char         char          one byte
  19.   boolean      char          one byte (0 = FALSE, 255 (!FALSE) = TRUE)
  20.   word         int           two bytes (integer type)
  21.   longint      double        four bytes (long integer type)
  22.  
  23.   TurBoard does not generally use floating point variables, so in most
  24.   cases the conversion is easy.  }
  25.  
  26.  
  27. { Security type, used throughout TurBoard for security.
  28.   GE = Greater Than or Equal Security requirement
  29.   E1 = Security Group 1    (0 = No Group)
  30.   E2 = Security Group 2    (0 = No Group)
  31.   E3 = Security Group 3    (0 = No Group)
  32.   E4 = Security Group 4    (0 = No Group)
  33.   K1 = Key requirement #1  (#0 = No key)
  34.   K2 = Key requirement #2  (#0 = No key)
  35.   K3 = Key requirement #3  (#0 = No key)
  36. }
  37.  
  38.   sectype = record
  39.     GE, E1, E2, E3, E4: byte;
  40.     K1, K2, K3: char;
  41.   end;
  42.  
  43. { Record type for FORUMS.DAT file.}
  44.  
  45.   forumtype = record
  46.     name: string[8];
  47.     qwknumb: word;           { used internally by TurBoard for QWK;
  48.                                this is the QWK forum number }
  49.     rsl: sectype;            { sl to read messages in this forum. }
  50.     esl: sectype;            { sl to enter messages in this forum. }
  51.     desc: string[60];        { description of this forum }
  52.     chairman: string[36];    { Actual name of chairman from USERS.DAT }
  53.     path: string[80];        { DOS path of this forum's data files }
  54.     basepw: string[10];      { Reserved }
  55.     alias: boolean;          { TRUE (255) = Alias names turned on
  56.                                FALSE (0) = Real names used }
  57.     anonymous: boolean;      { TRUE allows anonymous names }
  58.     private: boolean;        { TRUE allows private messages }
  59.     mailtype: char;          { N = Normal; F = Fidonet; E = Echo }
  60.     maxdaysold: longint;
  61.     maxmsgs: longint;
  62.     area: string[60];        { Fidonet AREA name }
  63.     origin: string[100];     { Individual origin line}
  64.     seenby: boolean;         { Reserved }
  65.     intromsg: char;          { Reserved }
  66.     reserved: array[1..150] of byte; { Reserved for future expansion NULLS }
  67.   end;
  68.  
  69. { Record type for ECHO.DAT file in the forum path it is for.}
  70.  
  71.   echotype = record
  72.     zone: word;              { Fido-style address }
  73.     net: word;
  74.     node: word;
  75.     point: word;
  76.     network: word;           { record number in NETWORKS.DAT }
  77.     reserved: array[1..50] of byte;  {Reserved for future expansion NULLS }
  78.   end;
  79.  
  80. { Record type for NETWORKS.DAT }
  81.  
  82.   networktype = record
  83.     name: string[8];         { name of the network }
  84.     zone: word;              { Our address in that network }
  85.     net: word;
  86.     node: word;
  87.     point: word;
  88.     ext: string[60];
  89.     archive: word;           { Archiver for network from SYSTEM.DAT }
  90.     dir: string[8];
  91.     rtzone: word;
  92.     rtnet: word;
  93.     rtnode: word;
  94.     rtpoint: word;
  95.     reserved: array[1..60] of byte; {Reserved for future expansion NULLS}
  96.   end;
  97.  
  98. { Record type for HEADERS.DAT }
  99.  
  100.   headertype = record
  101.     number: longint;
  102.     fromhere: boolean;
  103.     MSGID: string[30];
  104.     REPLY: string[30];
  105.     replyto: longint;
  106.     fromname: string[36];
  107.     fromloc: string[30];
  108.     toname: string[36];
  109.     toloc: string[30];
  110.     subject: string[36];
  111.     datetime: longint;
  112.     private: boolean;
  113.     fidotype: char;
  114.     deleted: boolean;
  115.     misc: string[8];
  116.     readdatetime: longint;
  117.     index: longint;
  118.     reserved: array[1..60] of byte;
  119.   end;
  120.  
  121. { Record type for MSGS.DAT }
  122.  
  123. { First part of message is pointed to by "index" from headertype.
  124.   Last record is identified by next = -1 }
  125.  
  126.   msgtype = record
  127.     data: string[128];
  128.     next: longint;
  129.   end;
  130.  
  131. { Record type for BBS List}
  132.  
  133.   BBSTyp   = Record
  134.           Name: string[36];
  135.           Sysop: string[36];
  136.           baud: string[8];
  137.           theme: string[20];
  138.           phone: string[12];
  139.           protocol: string[12];
  140.           network: string[30];
  141.           city: string[30];
  142.           software: string[20];
  143.           computer: string[20];
  144.           diskspace: longint;
  145.           NoLines: longint;
  146.           modemtype: string[20];
  147.           index: longint;
  148.           review: byte;
  149.           enteredby: longint;
  150.           local: boolean;
  151.           reserved: array[1..50] of byte;  { Reserved for future expansion }
  152.         end;
  153.  
  154. { Record type for User Indexes  A.NDX, B.NDX ...}
  155.  
  156.   IndexTyp = Record
  157.            phonetic: string[8];
  158.            number: longint;
  159.         end;
  160.  
  161. { Record type for MODEMS.DAT }
  162.  
  163.   ModemTyp = Record
  164.            name: string[90];
  165.            init: string[90];
  166.            terminit: string[90];
  167.            maxbaud: word;
  168.            offhook: string[20];
  169.            hangup: string[20];
  170.            ConnectString: String[20];
  171.            answer: string[10];
  172.            followbaud: byte;
  173.            ring: string[20];
  174.            ringing: string[20];
  175.            nocarrier: string[20];
  176.            timeout: byte;
  177.            lowerdtrpause: byte;
  178.          end;
  179.  
  180. { Record type for NODExxxx.DAT file for each node. }
  181.  
  182.   NodeType = Record
  183.           port: byte;
  184.           modemtype: byte;
  185.           syspath: string[90];
  186.           snoop: boolean;
  187.           minbaud, maxbaud: word;
  188.           reserved: array[1..40] of byte;
  189.         end;
  190.  
  191. { A YAK information file, internally used by TurBoard }
  192.  
  193.   Notifytype = array[0..100] of boolean;
  194.  
  195. { The internal representation of the marked file list }
  196.  
  197.   Filestacktype = array[1..10] of string[12];
  198.  
  199. { Record type for NODES.DAT file used for dropping to doors, etc. }
  200.  
  201.   NodesType = Record
  202.           Name: String[36];
  203.           Location: String[20];
  204.           Desc: String[32];
  205.           Action: Byte;
  206.           pbaud: longint;
  207.           cbaud: longint;
  208.           ANSIs: Boolean;
  209.           naplps: boolean;
  210.           menu: word;
  211.           instamp: LongInt;
  212.           instampsecs: LongInt;
  213.           ChatTime: Integer;
  214.           Maxtime: Integer;
  215.           SLName: String[20];
  216.           after: char;
  217.           modem: boolean;
  218.           cdpath: string[8];
  219.           cdname: string[30];
  220.           forum: string[8];
  221.           notify: notifytype;
  222.           filestack: filestacktype;
  223.           reserved: array[1..70] of byte; { Reserved for future expansion NULL}
  224.         end;
  225.  
  226. { Record type for USERS.DAT }
  227.  
  228.    UserType = Record
  229.            Name: String[36];
  230.            Pw: String[10];
  231.            SL: byte;
  232.            keys: string[20];
  233.            alias: string[36];
  234.            Street: String[30];
  235.            City: String[30];
  236.            HPhone: String[14];
  237.            WName: String[30];
  238.            WTitle: String[20];
  239.            WPhone: String[14];
  240.            Account: LongInt;
  241.            PointNumber: word;
  242.            FilePoints: longint;
  243.            TimeOn: Integer;
  244.            LastOn: LongInt;
  245.            LastDir: LongInt;
  246.            Width: Byte;
  247.            ScrnLength: Byte;
  248.            transfer1: Char;
  249.            archive: byte;
  250.            birthday: LongInt;
  251.            birthyear: word;
  252.            timeson: word;
  253.            downloads: word;
  254.            downloadk: longint;
  255.            uploads: word;
  256.            uploadk: longint;
  257.            msgentered: word;
  258.            msgread: longint;
  259.            Pause: Boolean;
  260.            FullScreen: Boolean;
  261.            Mail: byte;
  262.            Hack: byte;
  263.            clr: Boolean;
  264.            spellcheck: boolean;
  265.            expert: boolean;
  266.            forumintro: char;
  267.            menurotation: byte;
  268.            expiredate: longint;
  269.            expiresl: byte;
  270.            timebank: longint;
  271.            prompt: string[50];
  272.            reserved: array[1..60] of byte;
  273.          end;
  274.  
  275.  
  276. { Record type for SYSTEM.DAT }
  277.  
  278.   SystemType = Record
  279.            Name: String[80];
  280.            Password: String[10];
  281.            SysopPassword: String[10];
  282.            SysopHere: Boolean;
  283.            Sound: Boolean;
  284.            CallerNum: LongInt;
  285.            open1: Boolean;
  286.            quickpw: boolean;
  287.            aliasok: boolean;
  288.            TPath: String[80];
  289.            BBSPath: String[80];
  290.            bookpath: string[80];
  291.            APath: String[80];
  292.            UPath: String[80];
  293.            MPath: String[80];
  294.            FPath: String[80];
  295.            DPath: String[80];
  296.            YakPath: String[80];
  297.            BPath: String[80];
  298.            AdPath: String[80];
  299.            CBPath: String[80];
  300.            QUPath: String[80];
  301.            LogPath: String[80];
  302.            FDataPath: String[80];
  303.            FInPath: String[80];
  304.            FOutPath: String[80];
  305.            logupdate: byte;
  306.            TimeZone: String[30];
  307.            UPFileSL, uppvtsl, uppubsl: sectype;
  308.            uploaddir: string[8];
  309.            NewSL: Byte;
  310.            newkeys: string[20];
  311.            doscom: string[40];
  312.            secdad, secadcata, secdbbs, secbbstext,
  313.            secaddbookchap, secedchap, secaddnewbook, secaddbulletin,
  314.            secdelbul, seceditbul, secadddoor, seceditdoor, secedit,
  315.            sectype, seceditdirext, seceditdir, secdeldir, secaddfiledir,
  316.            secffext, secdeldirlist, secreadall, secaddforum, secentfido,
  317.            seceditforum, secmmsg, secdelforum, secdetaillog, secedituser,
  318.            secyak, secsetup, secenterresumes, seclngadd, seclngedit,
  319.            secreadresumes, secads, secbbslist, secdoor, seccb,
  320.            seceditcb, secqwk, secbook, secbul, secquest, secquestmod,
  321.            seclog, secart, secartedit, secdl: sectype;
  322.            fidopassthrough: boolean;
  323.            lastevent: longint;
  324.            InitPoints: Word;
  325.            credperk: Word;
  326.            regname, regserial: string[60];
  327.            credperdl: word;
  328.            dlkperpoint: word;
  329.            limitdltime: boolean;
  330.            asciiok, ansiok, naplpsok, future1ok, future2ok: boolean;
  331.            ultimebonus: byte;
  332.            fdtype: byte;
  333.            QWKname: string[8];
  334.            arcname: array[1..8] of string[10];
  335.            arcid: array[1..8] of char;
  336.            arccmd: array[1..8,1..2] of string[50];
  337.            arcprm: array[1..8,1..2] of string[50];
  338.            arcext: array[1..8] of string[3];
  339.            cddrive: array[1..8] of char;
  340.            cdname: array[0..8] of string[50];
  341.            cdavail: array[1..8] of boolean;
  342.            cdsl: array[1..8] of sectype;
  343.            viruspgm: string[60];
  344.            askfiledetail: boolean;
  345.            reserved: array[1..1000] of byte;
  346.          end;
  347.  
  348. { Record type for SECURITY.DAT }
  349.  
  350.   SecurityType = Record
  351.            Name: String[20];
  352.            Time: Integer;
  353.            reserved: array[1..50] of byte;
  354.           end;
  355.  
  356. { Record type for the language file. }
  357.  
  358.   langtype = string[100];
  359.  
  360. { Record type for YAK.DAT }
  361.  
  362.   YakType = Record
  363.            name: string[80];
  364.            description: string[60];
  365.            onceonly: boolean;
  366.            check: array[1..4] of word;
  367.            checkval: array[1..4] of longint;
  368.            blankresponce: string[80];
  369.            hotkey: boolean;
  370.            reserved: array[1..100] of byte; {Reserved for future expansion}
  371.          end;
  372.  
  373. { Record type for *.HOT }
  374.  
  375.   hottype = record
  376.            ch: char;
  377.            cmd: string[20];
  378.            gxt, gxb, gyt, gyb: real;  {graphics mouse activate box}
  379.            sl: sectype;
  380.            action: string[80];
  381.            reserved: array[1..20] of byte;
  382.          end;
  383.  
  384. { Record type for BULLETINS }
  385.  
  386.   BulletinType = Record
  387.            AutoRead: Boolean;
  388.            DateTime: LongInt;
  389.            SL: sectype;
  390.            Desc: String[60];
  391.            reserved: array[1..20] of byte;
  392.   end;
  393.  
  394. { Record type for *.NMA (located in the USERS directory)}
  395.  
  396.   NewMailType = Record
  397.     Number: LongInt;
  398.     Forum: String[8];
  399.     read: boolean;
  400.     reserved: array[1..10] of byte;
  401.   end;
  402.  
  403. { Record type for *.LOG }
  404.  
  405.   LogType = Record
  406.           Node: Byte;
  407.           DateTime: LongInt;
  408.           Action: Byte;
  409.           A: String[13];
  410.          end;
  411.  
  412.   othertyp = string[80];
  413.  
  414. { Record type for file directory }
  415.  
  416.   filedirtype = record
  417.     name: string[8];
  418.     usl: sectype;
  419.     dsl: sectype;
  420.     desc: string[34];
  421.     sort: byte;
  422.     newestfiledate: longint;
  423.     dirpath: string[80];
  424.     reserved: array[1..200] of byte;
  425.   end;
  426.  
  427. { Record type for file listings }
  428.  
  429.   filelisttype = record
  430.     name: string[12];
  431.     path: string[80];
  432.     deleted: boolean;
  433.     fdate: longint;
  434.     fsize: longint;
  435.     dsl: sectype;
  436.     postdate: longint;
  437.     detailed: longint;
  438.     desc: string[46];
  439.     dirname: string[8];
  440.     numbdownloads: word;
  441.     keywords: string[80];
  442.     uploadby: longint;
  443.     review: byte;
  444.     filetype: char;
  445.     reserved: array[1..100] of byte;
  446.   end;
  447.  
  448. { Record type for file listing indexes }
  449.  
  450.   indextype = record
  451.     name:string[12];
  452.     date:longint;
  453.     number:longint;
  454.   end;
  455.  
  456. { Record type for file listing reviews }
  457.  
  458.   reviewtype = record
  459.     usernumb: longint;
  460.     review: byte;
  461.   end;
  462.